package com.lanou.dllo.soccernews.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import com.lanou.dllo.soccernews.fragment.FragmentFactory;

/**
 * Created by dllo on 15/10/28.
 */
public class DirectVIewpageAdapter extends FragmentPagerAdapter {

    private String[] titles = {"重要", "节目", "足彩", "关注"};

    public DirectVIewpageAdapter(FragmentManager fm) {
        super(fm);
    }

    @Override
    public Fragment getItem(int position) {

        return FragmentFactory.createFragment2(position);
    }

    @Override
    public int getCount() {
        return titles.length;
    }

    public CharSequence getPageTitle(int position) {

        return titles[position];


    }


}